home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Apple Reference & Presen…tion Library 2 (Reseller)
/
Apple R&P Lib Reseller v2.0.iso
/
3-Demos
/
HyperCard Demos
/
HyperMovies
/
CL⁄1
/
CL_1
/
card_5615.txt
< prev
next >
Wrap
Text File
|
1989-10-27
|
8KB
|
364 lines
-- card: 5615 from stack: in
-- bmap block id: 10968
-- flags: 4000
-- background id: 6049
-- name: Connect Setup
----- HyperTalk script -----
on openCard
push recent card
hide menubar
global connectMode
if connectMode is empty then put "Simulation" into connectMode
repeat 5 times
get the highlight of card btn connectMode
set the highlight of card btn connectMode to not it
wait 5
end repeat
click at the loc of card btn connectMode
pass openCard
end openCard
--on closeCard
global connectMode,myHostName,myUserName,myPassword
put "Simulation" into connectMode --only support simulation for now
put card field "myHostName" into myHostName
put card field "myUserName" into myUserName
put card field "myPassword" into myPassword
pass closeCard
end closeCard
on changeConnectMode
get (highlight of the target) and false
set highlight of card btn "Simulation" to it
set highlight of card btn "Direct" to it
set highlight of card btn "Modem" to it
set highlight of card btn "AppleTalk" to it
set highlight of card btn "DECnet" to it
set highlight of the target to not it
global connectMode
put the short name of the target into connectMode
end changeConnectMode
-- part 3 (field)
-- low flags: 01
-- high flags: 2004
-- rect: left=170 top=85 right=321 bottom=487
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name:
-- part 18 (field)
-- low flags: 01
-- high flags: 0000
-- rect: left=306 top=110 right=223 bottom=458
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name: mode types
-- part 4 (field)
-- low flags: 01
-- high flags: 0000
-- rect: left=182 top=109 right=293 bottom=279
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 65535
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name: Headings
-- part 5 (field)
-- low flags: 03
-- high flags: 4000
-- rect: left=288 top=229 right=250 bottom=460
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name: myHostName
-- part 8 (field)
-- low flags: 03
-- high flags: 4000
-- rect: left=288 top=249 right=270 bottom=460
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name: myUserName
-- part 9 (field)
-- low flags: 03
-- high flags: 4000
-- rect: left=288 top=269 right=290 bottom=460
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 20
-- part name: myPassword
-- part 13 (button)
-- low flags: 00
-- high flags: 0006
-- rect: left=288 top=151 right=172 bottom=374
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Modem
----- HyperTalk script -----
on mouseUp
ChangeConnectMode
get word 1 of card field "baud rate"
if it is empty then
put "1200 baud" into card field "baud rate"
get 1200
end if
put "nivax" & it into card field "myHostName"
put empty into card field "myUserName"
put empty into card field "myPassword"
end mouseUp
-- part 14 (button)
-- low flags: 00
-- high flags: 0006
-- rect: left=288 top=171 right=192 bottom=396
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: AppleTalk
----- HyperTalk script -----
on mouseUp
get the short name of the target
answer it && "is not currently supported."
--ChangeConnectMode
end mouseUp
-- part 15 (button)
-- low flags: 00
-- high flags: 0006
-- rect: left=288 top=191 right=212 bottom=381
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: DECnet
----- HyperTalk script -----
on mouseUp
get the short name of the target
answer it && "is not currently supported."
--ChangeConnectMode
end mouseUp
-- part 16 (button)
-- low flags: 00
-- high flags: 0006
-- rect: left=288 top=131 right=152 bottom=364
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Direct
----- HyperTalk script -----
on mouseUp
ChangeConnectMode
put "nivax" into card field "myHostName"
put empty into card field "myUserName"
put empty into card field "myPassword"
end mouseUp
-- part 17 (button)
-- low flags: 00
-- high flags: 4006
-- rect: left=288 top=111 right=132 bottom=400
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Simulation
----- HyperTalk script -----
on mouseUp
ChangeConnectMode
put "My Host Name" into card field "myHostName"
put "My Name" into card field "myUserName"
put "My Password" into card field "myPassword"
if the commandKey is down then
--go to the data cards for the simulation
visual zoom open to gray
visual zoom open
go card 1 of background "Simulation Host"
end if
end mouseUp
-- part 20 (field)
-- low flags: 80
-- high flags: 0007
-- rect: left=27 top=109 right=234 bottom=161
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 65535
-- font id: 3
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: help
-- part 21 (field)
-- low flags: 01
-- high flags: 0004
-- rect: left=380 top=150 right=170 bottom=468
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 20
-- text size: 18
-- style flags: 0
-- line height: 18
-- part name: baud rate
----- HyperTalk script -----
on mouseDown
put "300 baud,1200 baud,2400 baud,9600 baud" into baudRateList
get itemOffset(card field "baud rate",baudRateList)
put item 1 of rect of card field "baud rate" into h
put item 2 of rect of card field "baud rate" into v
put item 1 of loc of card window into dh
put item 2 of loc of card window into dv
get PopupMenu(baudRateList, it, v+1+dv, h+dh+1)
if it <> 0 then
put item it of baudRateList into card field "baud rate"
send mouseUp to card btn "Modem"
end if
end mouseDown
-- part 25 (button)
-- low flags: 00
-- high flags: 0000
-- rect: left=410 top=32 right=80 bottom=480
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: go map
----- HyperTalk script -----
on mouseUp
put false into QuotaHasChanged
if not inDebug() then
hide menuBar
hide message box
hide tool window
hide pattern window
set cursor to 4
lock screen
go to card "Map of Regions"
send "EraseMap" to bkgnd "Map"
unlock screen with visual dissolve
send "RetrieveAllData" to bkgnd "Map"
else
visual dissolve
go to card "Map of Regions"
end if
end mouseUp
-- part contents for card part 4
----- text -----
Connection
Mode
Host Name
User Name
Password
-- part contents for card part 5
----- text -----
My Host Name
-- part contents for card part 18
----- text -----
Simulation
Direct
Modem
AppleTalk
DecNET
-- part contents for card part 21
----- text -----
9600 baud
-- part contents for card part 8
----- text -----
My Name
-- part contents for card part 9
----- text -----
My Password